﻿<ResourceDictionary
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d">
	<Style x:Key="MyButton" TargetType="{x:Type Button}">
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type Button}">
					<Grid>
						<Rectangle x:Name="bg" Stroke="Black" StrokeThickness="0" Visibility="Hidden">
							<Rectangle.Fill>
								<ImageBrush ImageSource="/skin/Button/btbg.png" Stretch="Uniform"/>
							</Rectangle.Fill>
						</Rectangle>
						<Rectangle x:Name="fg" Stroke="Black" StrokeThickness="0" Visibility="Hidden" RadiusX="0" RadiusY="0">
							<Rectangle.Fill>
								<ImageBrush ImageSource="/skin/Button/btfg.png" Stretch="Uniform"/>
							</Rectangle.Fill>
						</Rectangle>
						<TextBlock x:Name="textBlock" HorizontalAlignment="Center" Margin="0" TextWrapping="Wrap" Text="{TemplateBinding Content}" d:LayoutOverrides="Height" VerticalAlignment="Center" Foreground="#FF020F5C"/>
					</Grid>
					<ControlTemplate.Triggers>
						<Trigger Property="IsFocused" Value="True">
							<Setter Property="Visibility" TargetName="bg" Value="Visible"/>
							<Setter Property="Foreground" TargetName="textBlock" Value="#FF161616"/>
						</Trigger>
						<Trigger Property="IsDefaulted" Value="True"/>
						<MultiTrigger>
							<MultiTrigger.Conditions>
								<Condition Property="IsFocused" Value="False"/>
								<Condition Property="IsMouseOver" Value="True"/>
							</MultiTrigger.Conditions>
							<Setter
						Property="Visibility" TargetName="fg" Value="Visible"/>
						</MultiTrigger>
						<Trigger Property="IsPressed" Value="True"/>
						<Trigger Property="IsEnabled" Value="False"/>
					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>
	<Style x:Key="Buttonlist" TargetType="{x:Type Button}">
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type Button}">
					<Grid>
						<Grid.RowDefinitions>
							<RowDefinition Height="61.163"/>
							<RowDefinition Height="20.837"/>
						</Grid.RowDefinitions>
						<TextBlock Margin="0,0,0,5" TextWrapping="Wrap" Text="{TemplateBinding Content}" VerticalAlignment="Center" d:LayoutOverrides="Width, Height" Grid.Row="1" HorizontalAlignment="Center" Foreground="White"/>
						<Border x:Name="fg" BorderBrush="Black" BorderThickness="0" Grid.RowSpan="2" CornerRadius="3" Visibility="Hidden">
							<Border.Background>
								<ImageBrush ImageSource="/skin/ico/toolbar_hover.png" Stretch="Uniform"/>
							</Border.Background>
						</Border>
						<Border x:Name="bg" BorderBrush="Black" BorderThickness="0" Grid.RowSpan="2" CornerRadius="3" Visibility="Hidden">
							<Border.Background>
								<ImageBrush ImageSource="/skin/ico/toolbar_pushed.png" Stretch="Uniform"/>
							</Border.Background>
						</Border>
						<Rectangle Fill="{TemplateBinding Background}" Grid.RowSpan="1" Stroke="Black" Margin="2,6,2,2" StrokeThickness="0"/>
					</Grid>
					<ControlTemplate.Triggers>
						<Trigger Property="IsFocused" Value="True">
							<Setter Property="Visibility" TargetName="bg" Value="Visible"/>
						</Trigger>
						<Trigger Property="IsDefaulted" Value="True"/>
						<MultiTrigger>
							<MultiTrigger.Conditions>
								<Condition Property="IsMouseOver" Value="True"/>
								<Condition Property="IsFocused" Value="False"/>
							</MultiTrigger.Conditions>
							<Setter
						Property="Visibility" TargetName="fg" Value="Visible"/>
						</MultiTrigger>
						<Trigger Property="IsPressed" Value="True"/>
						<Trigger Property="IsEnabled" Value="False"/>
					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>
	<!-- 应该在此定义资源字典条目。-->
</ResourceDictionary>